/*
 * File Created: 2019-12-07 11:56:41
 * Author: 余保林 (yubaolin6@outlook.com)
 * Desc: 菜单相关接口
 * Last Modified: 2019-12-07 11:56:51
 * Modified By: 余保林 (yubaolin6@outlook.com>)
 */

import request from '@/utils/request'

/**
 * @param {*} params
 */
export function menuQuery() {
  return request.get(`/platform/security/actions/tree`)
}

/**
 * @param {*} data
 */
export function menuAdd(data) {
  return request.post('/platform/security/actions', data)
}

/**
 * @param {*} data
 */
export function menuEdit(data) {
  return request.patch(`/platform/security/actions/${data.id}`, data)
}

/**
 * @param {*} data
 */
export function menuDelete(id) {
  return request.delete(`/platform/security/actions/${id}`)
}
